import json

from config import BASE_DIR


def read_json(name):
    with open(BASE_DIR+f'/data/{name}.json', "r", encoding='utf8') as f:
        data = json.load(f)
        data_list = []

        for i in data:
            i.pop('desc')
            data_list.append(i)
            # data_list.append(i.get('like'))
        return data_list




